import unittest


from solution import Solution


class TestLc0200(unittest.TestCase):
    soluton_inst = None

    def setUp(self):
        if self.soluton_inst is None:
            self.soluton_inst = Solution()
        print("setUp...")

    def tearDown(self):
        self.soluton_inst = None
        print("tearDown...")

    def test_numIslands_case01(self):
        input = [
            ["1", "1", "1", "1", "0"],
            ["1", "1", "0", "1", "0"],
            ["1", "1", "0", "0", "0"],
            ["0", "0", "0", "0", "0"],
        ]
        _res = self.soluton_inst.numIslands(input)
        self.assertEqual(_res, 1)
        pass


if __name__ == '__main__':
    unittest.main()
